#include <func.h>

int main()
{
    if(!fork())
    {
        printf("i am child,pid=%d,ppid=%d,pgid=%d,sid=%d\n",
        getpid(),getppid(),getpgid(0),getsid(0)); 
        return 0;
    }
    else{
        printf("i am father,pid=%d,ppid=%d,pgid=%d,sid=%d\n",
        getpid(),getppid(),getpgid(0),getsid(0));
        return 0;
    }
}